/*
 * Copyright (c) 2021, 2022, yzfh.cn All rights reserved.
 *
 */
package com.ly.mp;


import com.baomidou.mybatisplus.annotation.DbType;
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author yzfh
 * @Date 2022/02/24 星期四 15:40:32
 */
@Configuration
@MapperScan("com.ly.mp.mapper")
public class MybatisPlusConfig {


    /**
     * 配置分页插件
     * 新增 MybatisPlusInterceptor 解决 多租户和分页 插件一级和二级缓存不正确问题
     * @return
     */
   /* @Bean
    public MybatisPlusInterceptor  mybatisPlusInterceptor () {
        MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
        interceptor.addInnerInterceptor(new PaginationInnerInterceptor(DbType.MYSQL));
        return interceptor;
    }
*/
}
